<template>
    <el-card class="global-overview">
      <template #header>
        <div class="card-header">
          <h2>全局进度概览</h2>
        </div>
      </template>
      <el-table :data="theses" style="width: 100%">
        <el-table-column prop="title" label="论文标题" />
        <el-table-column prop="progress" label="进度" width="180">
          <template #default="scope">
            <el-progress :percentage="scope.row.progress" />
          </template>
        </el-table-column>
      </el-table>
    </el-card>
  </template>

  <script setup>
  import { ElCard, ElTable, ElTableColumn, ElProgress } from 'element-plus'

  defineProps({
    theses: {
      type: Array,
      required: true
    }
  })
  </script>

  <style scoped>
  .global-overview {
    margin-bottom: 20px;
  }

  .card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  </style>